//package com.example.demo.config;
//
//import org.springframework.context.annotation.Configuration;
//import org.springframework.web.servlet.ViewResolver;
//import org.springframework.web.servlet.config.annotation.DefaultServletHandlerConfigurer;
//import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
//import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
//import org.springframework.web.servlet.config.annotation.ViewResolverRegistry;
//import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;
//import org.springframework.web.servlet.view.InternalResourceViewResolver;
//
//@Configuration
//public class ApplicationConfigAdapter extends WebMvcConfigurerAdapter {
//  @Override
//  public void configureDefaultServletHandling(DefaultServletHandlerConfigurer configurer) {
//    configurer.enable();
//  }
//
//  @Override
//  public void addInterceptors(InterceptorRegistry registry) {
//    super.addInterceptors(registry);
//  }
//
//  @Override
//  public void addResourceHandlers(ResourceHandlerRegistry registry) {
//    super.addResourceHandlers(registry);
//    registry.addResourceHandler(new String[] { "/**" }).addResourceLocations(new String[] { "classpath:/public/" });
//  }
//
//  @Override
//  public void configureViewResolvers(ViewResolverRegistry registry) {
//    super.configureViewResolvers(registry);
//    InternalResourceViewResolver viewResolver = new InternalResourceViewResolver();
//    viewResolver.setPrefix("/pages/");
//    viewResolver.setSuffix(".jsp");
//    registry.viewResolver((ViewResolver)viewResolver);
//  }
//}
